package cn.demoncat.util.lang.constant;

import cn.demoncat.util.lang.entity.MapSs;

import java.time.ZoneId;
import java.time.format.DateTimeFormatter;
import java.util.TimeZone;

/**
 * 描述：时间常量
 *
 * @author 延晓磊
 *
 * @since 2016年6月26日
 */
public final class DateConstant {

	/**
	 * 季节
	 */
	public static final MapSs QUARTER_MAP = MapSs.getInstance("1","春","2","夏","3","秋","4","冬");

	/**
	 * 系统时区Name：GMT+08:00
	 */
	public static final String ZONE_NAME = ZoneId.systemDefault().getId();
	/**
	 * 系统时区ID：GMT+08:00
	 */
	public static final ZoneId ZONE_ID = ZoneId.systemDefault();
	/**
	 * 系统时区：GMT+08:00
	 */
	public static final TimeZone ZONE = TimeZone.getDefault();
	
	/**
	 * 时区
	 */
	public static final String TIME_ZONE = "Asia/Shanghai";
	/**
	 * 时区 - 纽约
	 */
	public static final String TIME_ZONE_NewYork = "America/New_York";
	/**
	 * 时区 - 伦敦
	 */
	public static final String TIME_ZONE_London = "Europe/London";
	
	/**
     * 一天的小时数
     */
    public static final int HOURS_OF_DAY = 24;
    /**
     * 一小时的分钟数
     */
    public static final int MINUTES_OF_HOUR = 60;
    /**
     * 一天的分钟数
     */
    public static final int MINUTES_OF_DAY = MINUTES_OF_HOUR * HOURS_OF_DAY;
    /**
     * 一分钟的秒数
     */
    public static final int SECONDS_OF_MINUTE = 60;
    /**
     * 一小时的秒数
     */
    public static final int SECONDS_OF_HOUR = SECONDS_OF_MINUTE * MINUTES_OF_HOUR;
    /**
     * 一天的秒数
     */
    public static final int SECONDS_OF_DAY = SECONDS_OF_HOUR * HOURS_OF_DAY;
    /**
     * 一秒的毫秒数
     */
    public static final int MILLIS_OF_SECOND = 1000;
    /**
     * 一分钟的毫秒数
     */
    public static final int MILLIS_OF_MINUTE = MILLIS_OF_SECOND * SECONDS_OF_MINUTE;
    /**
     * 一小时的毫秒数
     */
    public static final int MILLIS_OF_HOUR = MILLIS_OF_SECOND * SECONDS_OF_HOUR;
    /**
     * 一天的毫秒数
     */
    public static final int MILLIS_OF_DAY = MILLIS_OF_SECOND * SECONDS_OF_DAY;

    /**
	 * Date格式：yyyy-MM-dd
	 */
    public static final String DATE_PATTERN = "yyyy-MM-dd";
    /**
   	 * Date格式：yyyy/MM/dd
   	 */
       public static final String DATE_PATTERN_FILE = "yyyy/MM/dd";
    /**
	 * Date格式：y年M月d日
	 */
    public static final String DATE_PATTERN_ZH = "yyyy年MM月dd日";
	/**
	 * Date格式：yyyy
	 */
	public static final String YEAR_PATTERN = "yyyy";
	/**
	 * Date格式：y年
	 */
	public static final String YEAR_PATTERN_ZH = "yyyy年";
    /**
   	 * Date格式：yyyy-MM
   	 * 
   	 * 注意：年+月不能转换日期，必须有日
   	 */
	public static final String MONTH_PATTERN = "yyyy-MM";
	 /**
   	 * Date格式：yyyy/MM
   	 * 
   	 * 注意：年+月不能转换日期，必须有日
   	 */
	public static final String MONTH_PATTERN_FILE = "yyyy/MM";
	/**
   	 * Date格式：y年M月
   	 * 
   	 * 注意：年+月不能转换日期，必须有日
   	 */
	public static final String MONTH_PATTERN_ZH = "yyyy年MM月";
    /**
	 * Date格式：yyyyMMdd
	 */
    public static final String DATE_PATTERN_NUM = "yyyyMMdd";
	/**
	 * Date格式：yyMMdd
	 */
	public static final String SMALL_DATE_PATTERN_NUM = "yyMMdd";
    /**
   	 * Date格式：yyyyMM
   	 */
    public static final String MONTH_PATTERN_NUM = "yyyyMM";
    /**
	 * Time格式：HH:mm:ss
	 */
    public static final String TIME_PATTERN = "HH:mm:ss";
    /**
   	 * Time格式：HH时mm分ss秒
   	 */
	public static final String TIME_PATTERN_ZH = "HH时mm分ss秒";
    /**
	 * Time格式：HHmmss
	 */
    public static final String TIME_PATTERN_NUM = "HHmmss";
    /**
   	 * DateTime格式：yyyy-MM-dd HH
   	 */
	public static final String DATE_HOUR_PATTERN = "yyyy-MM-dd HH";
	/**
	 * DateTime格式：yyyy年MM月dd日 HH时mm分ss秒
	 */
	public static final String DATE_TIME_PATTERN_ZH = "yyyy年MM月dd日 HH时mm分ss秒";
    /**
   	 * DateTime格式：yyyy-MM-dd HH:mm:ss
   	 */
	public static final String DATE_TIME_PATTERN = "yyyy-MM-dd HH:mm:ss";
	/**
   	 * DateTime格式：yyyy-MM-dd'T'HH:mm:ss
   	 */
	public static final String DATE_T_TIME_PATTERN = "yyyy-MM-dd'T'HH:mm:ss";
	/**
   	 * DateTime格式：yyyyMMddHHmmss
   	 */
	public static final String DATE_TIME_PATTERN_NUM = "yyyyMMddHHmmss";
	
	/**
	 * 毫秒格式：yyyyMMddHHmmssSSS
	 */
	public static final String NANO_PATTERN_NUM = "yyyyMMddHHmmssSSS";
	
    /**
	 * LocalDate格式：yyyy-MM-dd
	 */
    public static final DateTimeFormatter DATE_FROMAT = DateTimeFormatter.ofPattern(DATE_PATTERN);
    /**
	 * LocalDate格式：yyyy/MM/dd
	 */
    public static final DateTimeFormatter DATE_FORMAT_FILE = DateTimeFormatter.ofPattern(DATE_PATTERN_FILE);
    /**
     * LocalDate格式：y年M月d日
     */
    public static final DateTimeFormatter DATE_FORMAT_ZH = DateTimeFormatter.ofPattern(DATE_PATTERN_ZH);
    /**
	 * LocalDate格式：yyyyMMdd
	 */
    public static final DateTimeFormatter DATE_FORMAT_NUM = DateTimeFormatter.ofPattern(DATE_PATTERN_NUM);
	/**
	 * LocalDate格式：yyMMdd
	 */
	public static final DateTimeFormatter SMALL_DATE_FORMAT_NUM = DateTimeFormatter.ofPattern(SMALL_DATE_PATTERN_NUM);
	/**
	 * LocalDate格式：yyyy
	 */
	public static final DateTimeFormatter YEAR_FORMAT = DateTimeFormatter.ofPattern(YEAR_PATTERN);
	/**
	 * LocalDate格式：yyyy年
	 */
	public static final DateTimeFormatter YEAR_FORMAT_ZH = DateTimeFormatter.ofPattern(YEAR_PATTERN_ZH);
    /**
	 * LocalDate格式：yyyy-MM
	 */
    public static final DateTimeFormatter MONTH_FORMAT = DateTimeFormatter.ofPattern(MONTH_PATTERN);
    /**
     * LocalDate格式：yyyy/MM
     */
    public static final DateTimeFormatter MONTH_FORMAT_FILE = DateTimeFormatter.ofPattern(MONTH_PATTERN_FILE);
    /**
     * LocalDate格式：y年M月
     */
    public static final DateTimeFormatter MONTH_FORMAT_ZH = DateTimeFormatter.ofPattern(MONTH_PATTERN_ZH);
    /**
	 * LocalDate格式：yyyyMM
	 */
    public static final DateTimeFormatter MONTH_FORMAT_NUM = DateTimeFormatter.ofPattern(MONTH_PATTERN_NUM);
    /**
	 * LocalTime格式：HH时mm分ss秒
	 */
    public static final DateTimeFormatter TIME_FORMAT_ZH = DateTimeFormatter.ofPattern(TIME_PATTERN_ZH);
    /**
	 * LocalTime格式：HH:mm:ss
	 */
    public static final DateTimeFormatter TIME_FORMAT = DateTimeFormatter.ofPattern(TIME_PATTERN);
    /**
	 * LocalTime格式：HHmmss
	 */
    public static final DateTimeFormatter TIME_FORMAT_NUM = DateTimeFormatter.ofPattern(TIME_PATTERN_NUM);
    /**
   	 * LocalDateTime格式：yyyy-MM-dd HH
   	 */
	public static final DateTimeFormatter DATE_HOUR_FORMAT = DateTimeFormatter.ofPattern(DATE_HOUR_PATTERN);
	 /**
   	 * LocalDateTime格式：yyyy年MM月dd日 HH时mm分ss秒
   	 */
	public static final DateTimeFormatter DATE_TIME_FORMAT_ZH = DateTimeFormatter.ofPattern(DATE_TIME_PATTERN_ZH);
    /**
   	 * LocalDateTime格式：yyyy-MM-dd HH:mm:ss
   	 */
	public static final DateTimeFormatter DATE_TIME_FORMAT = DateTimeFormatter.ofPattern(DATE_TIME_PATTERN);
	/**
	 * LocalDateTime格式：yyyy-MM-dd'T'HH:mm:ss
	 */
	public static final DateTimeFormatter DATE_T_TIME_FORMAT = DateTimeFormatter.ofPattern(DATE_T_TIME_PATTERN);
	/**
   	 * LocalDateTime格式：yyyyMMddHHmmss
   	 */
	public static final DateTimeFormatter DATE_TIME_FORMAT_NUM = DateTimeFormatter.ofPattern(DATE_TIME_PATTERN_NUM);
	/**
	 * LocalDateTime格式：yyyyMMddHHmmssSSS
	 */
	public static final DateTimeFormatter NANO_FORMAT_NUM = DateTimeFormatter.ofPattern(NANO_PATTERN_NUM);
	
 
}
